// Created from GenerationTemplate
// For Decisions HL7 Engine
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;
using System.Reflection;
using DecisionsFramework.Design.Properties;
using Decisions.HL7.Generated.AbstractMessage;
using Decisions.HL7.DataTypes;
using ST = System.String;
using SI = System.String;
using TX = System.String;
using FT = System.String;
using IS = System.String;
using ID = System.String;
using SNM = System.String;

namespace Decisions.HL7.Message
{
    [DataContract]
	public class INV : AbstractSegment
    {

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("1 Substance Identifier",1)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.True,"CE_0451")]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.True,"CWE")]
		[SubstanceIdentifier]
	    public CWE SubstanceIdentifier {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("2 Substance Status",2)]
  	    [HL7Field(HL7Version.v24, 2, HL7Repeat.True, HL7Required.True,"CE_0383")]
  	    [HL7Field(HL7Version.v25, 2, HL7Repeat.True, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 2, HL7Repeat.True, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 2, HL7Repeat.True, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 2, HL7Repeat.True, HL7Required.True,"CWE")]
		[SubstanceStatus]
	    public CWE[] SubstanceStatus {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("3 Substance Type",3)]
  	    [HL7Field(HL7Version.v24, 3, HL7Repeat.False, HL7Required.True,"CE_0384")]
  	    [HL7Field(HL7Version.v25, 3, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 3, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 3, HL7Repeat.False, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 3, HL7Repeat.False, HL7Required.True,"CWE")]
		[SubstanceType]
	    public CWE SubstanceType {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("4 Inventory Container Identifier",4)]
  	    [HL7Field(HL7Version.v24, 4, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v25, 4, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 4, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 4, HL7Repeat.False, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 4, HL7Repeat.False, HL7Required.True,"CWE")]
		[notableforCE]
	    public CWE InventoryContainerIdentifier {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("5 Container Carrier Identifier",5)]
  	    [HL7Field(HL7Version.v24, 5, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v25, 5, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 5, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 5, HL7Repeat.False, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 5, HL7Repeat.False, HL7Required.True,"CWE")]
		[notableforCE]
	    public CWE ContainerCarrierIdentifier {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("6 Position on Carrier",6)]
  	    [HL7Field(HL7Version.v24, 6, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v25, 6, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 6, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 6, HL7Repeat.False, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 6, HL7Repeat.False, HL7Required.True,"CWE")]
		[notableforCE]
	    public CWE PositiononCarrier {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("7 Initial Quantity",7)]
  	    [HL7Field(HL7Version.v24, 7, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v25, 7, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v251, 7, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v26, 7, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v27, 7, HL7Repeat.False, HL7Required.True,"NM")]
	    public NM InitialQuantity {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("8 Current Quantity",8)]
  	    [HL7Field(HL7Version.v24, 8, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v25, 8, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v251, 8, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v26, 8, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v27, 8, HL7Repeat.False, HL7Required.True,"NM")]
	    public NM CurrentQuantity {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("9 Available Quantity",9)]
  	    [HL7Field(HL7Version.v24, 9, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v25, 9, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v251, 9, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v26, 9, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v27, 9, HL7Repeat.False, HL7Required.True,"NM")]
	    public NM AvailableQuantity {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("10 Consumption Quantity",10)]
  	    [HL7Field(HL7Version.v24, 10, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v25, 10, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v251, 10, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v26, 10, HL7Repeat.False, HL7Required.True,"NM")]
  	    [HL7Field(HL7Version.v27, 10, HL7Repeat.False, HL7Required.True,"NM")]
	    public NM ConsumptionQuantity {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("11 Quantity Units",11)]
  	    [HL7Field(HL7Version.v24, 11, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v25, 11, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 11, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 11, HL7Repeat.False, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 11, HL7Repeat.False, HL7Required.True,"CWE")]
		[notableforCE]
	    public CWE QuantityUnits {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("12 Expiration Date/Time",12)]
  	    [HL7Field(HL7Version.v24, 12, HL7Repeat.False, HL7Required.True,"TS")]
  	    [HL7Field(HL7Version.v25, 12, HL7Repeat.False, HL7Required.True,"TS")]
  	    [HL7Field(HL7Version.v251, 12, HL7Repeat.False, HL7Required.True,"TS")]
  	    [HL7Field(HL7Version.v26, 12, HL7Repeat.False, HL7Required.True,"DTM")]
  	    [HL7Field(HL7Version.v27, 12, HL7Repeat.False, HL7Required.True,"DTM")]
	    public DTM ExpirationDateTime {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("13 First Used Date/Time",13)]
  	    [HL7Field(HL7Version.v24, 13, HL7Repeat.False, HL7Required.True,"TS")]
  	    [HL7Field(HL7Version.v25, 13, HL7Repeat.False, HL7Required.True,"TS")]
  	    [HL7Field(HL7Version.v251, 13, HL7Repeat.False, HL7Required.True,"TS")]
  	    [HL7Field(HL7Version.v26, 13, HL7Repeat.False, HL7Required.True,"DTM")]
  	    [HL7Field(HL7Version.v27, 13, HL7Repeat.False, HL7Required.True,"DTM")]
	    public DTM FirstUsedDateTime {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("14 On Board Stability Duration",14)]
  	    [HL7Field(HL7Version.v24, 14, HL7Repeat.False, HL7Required.True,"TQ")]
  	    [HL7Field(HL7Version.v25, 14, HL7Repeat.False, HL7Required.True,"TQ")]
  	    [HL7Field(HL7Version.v251, 14, HL7Repeat.False, HL7Required.True,"TQ")]
  	    [HL7Field(HL7Version.v26, 14, HL7Repeat.False, HL7Required.True,"TQ")]
	    public TQ OnBoardStabilityDuration {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("15 Test/Fluid Identifier(s)",15)]
  	    [HL7Field(HL7Version.v24, 15, HL7Repeat.True, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v25, 15, HL7Repeat.True, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 15, HL7Repeat.True, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 15, HL7Repeat.True, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 15, HL7Repeat.True, HL7Required.True,"CWE")]
		[notableforCE]
	    public CWE[] TestFluidIdentifiers {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("16 Manufacturer Lot Number",16)]
  	    [HL7Field(HL7Version.v24, 16, HL7Repeat.False, HL7Required.True,"ST")]
  	    [HL7Field(HL7Version.v25, 16, HL7Repeat.False, HL7Required.True,"ST")]
  	    [HL7Field(HL7Version.v251, 16, HL7Repeat.False, HL7Required.True,"ST")]
  	    [HL7Field(HL7Version.v26, 16, HL7Repeat.False, HL7Required.True,"ST")]
  	    [HL7Field(HL7Version.v27, 16, HL7Repeat.False, HL7Required.True,"ST")]
	    public ST ManufacturerLotNumber {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("17 Manufacturer Identifier",17)]
  	    [HL7Field(HL7Version.v24, 17, HL7Repeat.False, HL7Required.True,"CE_0385")]
  	    [HL7Field(HL7Version.v25, 17, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 17, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 17, HL7Repeat.False, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 17, HL7Repeat.False, HL7Required.True,"CWE")]
		[ManufacturerIdentifier]
	    public CWE ManufacturerIdentifier {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("18 Supplier Identifier",18)]
  	    [HL7Field(HL7Version.v24, 18, HL7Repeat.False, HL7Required.True,"CE_0386")]
  	    [HL7Field(HL7Version.v25, 18, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v251, 18, HL7Repeat.False, HL7Required.True,"CE")]
  	    [HL7Field(HL7Version.v26, 18, HL7Repeat.False, HL7Required.True,"CWE")]
  	    [HL7Field(HL7Version.v27, 18, HL7Repeat.False, HL7Required.True,"CWE")]
		[SupplierIdentifier]
	    public CWE SupplierIdentifier {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("19 On Board Stability Time",19)]
  	    [HL7Field(HL7Version.v25, 19, HL7Repeat.False, HL7Required.True,"CQ")]
  	    [HL7Field(HL7Version.v251, 19, HL7Repeat.False, HL7Required.True,"CQ")]
  	    [HL7Field(HL7Version.v26, 19, HL7Repeat.False, HL7Required.True,"CQ")]
  	    [HL7Field(HL7Version.v27, 19, HL7Repeat.False, HL7Required.True,"CQ")]
	    public CQ OnBoardStabilityTime {get;set;}

        /// -----------------------------
        /// -----------------------------
		[DataMember]
    	[PropertyClassification("20 Target Value",20)]
  	    [HL7Field(HL7Version.v25, 20, HL7Repeat.False, HL7Required.True,"CQ")]
  	    [HL7Field(HL7Version.v251, 20, HL7Repeat.False, HL7Required.True,"CQ")]
  	    [HL7Field(HL7Version.v26, 20, HL7Repeat.False, HL7Required.True,"CQ")]
  	    [HL7Field(HL7Version.v27, 20, HL7Repeat.False, HL7Required.True,"CQ")]
	    public CQ TargetValue {get;set;}


	    [DataMember]
        [PropertyClassification("AdditionalValue1", 21)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue1 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue2", 22)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue2 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue3", 23)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue3 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue4", 24)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue4 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue5", 25)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue5 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue6", 26)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue6 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue7", 27)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue7 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue8", 28)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue8 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue9", 29)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue9 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue10", 30)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue10 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue11", 31)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue11 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue12", 32)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue12 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue13", 33)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue13 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue14", 34)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue14 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue15", 35)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue15 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue16", 36)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue16 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue17", 37)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue17 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue18", 38)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue18 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue19", 39)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue19 { get; set; }

		    [DataMember]
        [PropertyClassification("AdditionalValue20", 40)]
		[HL7Field(HL7Version.v23, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v231, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v24, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v25, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v251, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v26, 1, HL7Repeat.False, HL7Required.False)]
  	    [HL7Field(HL7Version.v27, 1, HL7Repeat.False, HL7Required.False)]
		public string AdditionalValue20 { get; set; }

	

		internal override void ConsumeTextSegment(string segmentTextData, HL7ParserOptions options)
		{
			string[] segmentTextParts = segmentTextData.Split(new char[] { options.FieldSep }, StringSplitOptions.None);
			SubstanceIdentifier = (CWE)ParseTextAtPositionIntoData(segmentTextParts, 1, options, typeof(CWE), "INV.1");
	    	SubstanceStatus = (CWE[])ParseTextAtPositionIntoDataArray<CWE>(segmentTextParts, 2, options, "INV.2");
			SubstanceType = (CWE)ParseTextAtPositionIntoData(segmentTextParts, 3, options, typeof(CWE), "INV.3");
			InventoryContainerIdentifier = (CWE)ParseTextAtPositionIntoData(segmentTextParts, 4, options, typeof(CWE), "INV.4");
			ContainerCarrierIdentifier = (CWE)ParseTextAtPositionIntoData(segmentTextParts, 5, options, typeof(CWE), "INV.5");
			PositiononCarrier = (CWE)ParseTextAtPositionIntoData(segmentTextParts, 6, options, typeof(CWE), "INV.6");
			InitialQuantity = (NM)ParseTextAtPositionIntoData(segmentTextParts, 7, options, typeof(NM), "INV.7");
			CurrentQuantity = (NM)ParseTextAtPositionIntoData(segmentTextParts, 8, options, typeof(NM), "INV.8");
			AvailableQuantity = (NM)ParseTextAtPositionIntoData(segmentTextParts, 9, options, typeof(NM), "INV.9");
			ConsumptionQuantity = (NM)ParseTextAtPositionIntoData(segmentTextParts, 10, options, typeof(NM), "INV.10");
			QuantityUnits = (CWE)ParseTextAtPositionIntoData(segmentTextParts, 11, options, typeof(CWE), "INV.11");
			ExpirationDateTime = (DTM)ParseTextAtPositionIntoData(segmentTextParts, 12, options, typeof(DTM), "INV.12");
			FirstUsedDateTime = (DTM)ParseTextAtPositionIntoData(segmentTextParts, 13, options, typeof(DTM), "INV.13");
			OnBoardStabilityDuration = (TQ)ParseTextAtPositionIntoData(segmentTextParts, 14, options, typeof(TQ), "INV.14");
	    	TestFluidIdentifiers = (CWE[])ParseTextAtPositionIntoDataArray<CWE>(segmentTextParts, 15, options, "INV.15");
			ManufacturerLotNumber = (ST)ParseTextAtPositionIntoData(segmentTextParts, 16, options, typeof(ST), "INV.16");
			ManufacturerIdentifier = (CWE)ParseTextAtPositionIntoData(segmentTextParts, 17, options, typeof(CWE), "INV.17");
			SupplierIdentifier = (CWE)ParseTextAtPositionIntoData(segmentTextParts, 18, options, typeof(CWE), "INV.18");
			OnBoardStabilityTime = (CQ)ParseTextAtPositionIntoData(segmentTextParts, 19, options, typeof(CQ), "INV.19");
			TargetValue = (CQ)ParseTextAtPositionIntoData(segmentTextParts, 20, options, typeof(CQ), "INV.20");
		}

		public string GetER7(HL7ParserOptions options) {
			List<string> segmentParts = new List<string>();
			segmentParts.Add("INV");
			segmentParts.Add(GetER7TextForSegmentPart(SubstanceIdentifier, options));
		    segmentParts.Add(GetER7TextForSegmentArrayPart(SubstanceStatus, options));
			segmentParts.Add(GetER7TextForSegmentPart(SubstanceType, options));
			segmentParts.Add(GetER7TextForSegmentPart(InventoryContainerIdentifier, options));
			segmentParts.Add(GetER7TextForSegmentPart(ContainerCarrierIdentifier, options));
			segmentParts.Add(GetER7TextForSegmentPart(PositiononCarrier, options));
			segmentParts.Add(GetER7TextForSegmentPart(InitialQuantity, options));
			segmentParts.Add(GetER7TextForSegmentPart(CurrentQuantity, options));
			segmentParts.Add(GetER7TextForSegmentPart(AvailableQuantity, options));
			segmentParts.Add(GetER7TextForSegmentPart(ConsumptionQuantity, options));
			segmentParts.Add(GetER7TextForSegmentPart(QuantityUnits, options));
			segmentParts.Add(GetER7TextForSegmentPart(ExpirationDateTime, options));
			segmentParts.Add(GetER7TextForSegmentPart(FirstUsedDateTime, options));
			segmentParts.Add(GetER7TextForSegmentPart(OnBoardStabilityDuration, options));
		    segmentParts.Add(GetER7TextForSegmentArrayPart(TestFluidIdentifiers, options));
		    segmentParts.Add(ManufacturerLotNumber);
			segmentParts.Add(GetER7TextForSegmentPart(ManufacturerIdentifier, options));
			segmentParts.Add(GetER7TextForSegmentPart(SupplierIdentifier, options));
			segmentParts.Add(GetER7TextForSegmentPart(OnBoardStabilityTime, options));
			segmentParts.Add(GetER7TextForSegmentPart(TargetValue, options));
			return string.Join("" + options.FieldSep, segmentParts.ToArray());
		}

    }
}

